<?php
/**
 * test blueprint css framework
 * @package    
 * @author     ben
 */
class printAction extends WacCommonActions
{
    public function removeAllJavaScripts()
    {
        $scripts = $this->getResponse()->getJavascripts();
        print_r($scripts);
        if(count($scripts)>0)
        {
            foreach($scripts as $script)
            {
//                echo "<br/>ffff: ".$script;
                $this->getResponse()->removeJavascript($script);
            }

        }

        $scripts = $this->getResponse()->getStylesheets();
        print_r($scripts);
        if(count($scripts)>0)
        {
            foreach($scripts as $script)
            {
//                echo "<br/>ffff: ".$script;
                $this->getResponse()->removeStylesheet($script);
            }

        }

    }
    
    public function execute($request)
    {
        $this->setTemplate("print2");
        $this->initPrintInclusion();
        
//        // js required
//        $this->getResponse()->addJavaScript('jquery/jquery.layout.js', 'last');
//        $this->getResponse()->addJavaScript('jquery/plugins/jqgrid/i18n/grid.locale-en.js', 'last');
//        $this->getResponse()->addJavaScript('jquery/plugins/jqgrid/jquery.jqGrid.min.js', 'last');
//        $this->getResponse()->addJavaScript('jquery/jquery.tablednd.js', 'last');
//        $this->getResponse()->addJavaScript('jquery/jquery.contextmenu.js', 'last');
//        $this->getResponse()->addJavaScript('jquery/ui.multiselect.js', 'last');
//
        // css required

//        $this->getResponse()->addStylesheet("blueprint/screen.css", 'last', array("media"=>"screen, projection"));
//        $this->getResponse()->addStylesheet("blueprint/print.css", 'last', array("media"=>"print"));
//        $this->getResponse()->addStylesheet("blueprint/ie.css", 'last', array("media"=>"screen, projection"));

        
//        //component js required, begin
//        $this->getResponse()->addJavaScript("backend/test/".__CLASS__.".js", 'last');
//        //component js required, begin
//
//        //component css required, begin
//        $this->getResponse()->addStylesheet("backend/test/".__CLASS__.".css", 'last');
//        //component css required, begin
//
//       $this->setLayout("layout_1");
    }
}